import {EntityId, PageQueryParams} from "kf-web-library";
import {JournalPeriod, JournalSubscribe, User} from "@/services";

export interface ShippingRecordPageQueryParams extends Partial<PageQueryParams> {
  searchText?: string;
  ids?: EntityId[];
}

export interface ShippingRecord {
  id: EntityId; //主键
  subscribe: JournalSubscribe; //订阅记录表
  shippingType: string; //发送类型 ShippingType
  period: JournalPeriod; //刊期
  shippingTime: string; //发货时间
  shippingUser: User; //发货人
  logisticsCompany: string; //物流公司
  trackingNumber: string; //运单号
  email: string; //接收邮箱
  ignoreStatus: boolean; //是否忽略状态发货
}

export interface ShippingRecord_Create {
  subscribeId: number; //订阅记录表
  shippingType: string; //发送类型 ShippingType
  periodId: number; //刊期ID
  logisticsCompany: string; //物流公司
  trackingNumber: string; //运单号
  email: string; //接收邮箱
  ignoreStatus: boolean; //强制发货(强制发货不受状态现在,用于补发)
}



export interface ShippingRecord_Modify extends ShippingRecord_Create {
  id: EntityId;
}

export interface ShippingRecord_Patch extends Partial<ShippingRecord_Modify> {
  id: EntityId;
}

